import { request } from "@/utils/request"

export const PostRegistration = async (data: any) => {
    const response = await request({
        url: `/api/Registration`,
        method: 'post',
        data: data
    })
    console.log(response)
    return response
}

export const GetRegistrations = () => {
    return request({
        url: `/api/Registration`,
        method: 'get',
    })
}

export const PutRegistration = (id: number, data: any) => {
    return request({
        url: `/api/Registration/${id}`,
        method: 'put',
        data: data
    })
}

export const DeleteRegistration = (id: number) => {
    return request({
        url: `api/Registration/${id}`,
        method: 'delete'
    })
}